package com.example.peibei.service.presenter;

import com.dingtao.common.core.DataCall;
import com.dingtao.common.core.WDPresenter;
import com.dingtao.common.core.http.IAppRequest;

import io.reactivex.Observable;

public class FollowSquareDetailPresenter extends WDPresenter<IAppRequest> {
    public FollowSquareDetailPresenter(DataCall dataCall) {
        super(dataCall);
    }

    @Override
    protected Observable getModel(Object... args) {
        int follow = (Integer) args[0];
        if (follow == 0) {
            return iRequest.followCancelSuqareDetail((String) args[1], (String) args[2],1);
        } else {
            return iRequest.followCancelSuqareDetail((String) args[1], (String) args[2],0);
        }
    }
}
